package net.lab1024.sa.admin.module.business.shop.domain.form;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import net.lab1024.sa.base.common.json.deserializer.FileKeyVoDeserializer;
import net.lab1024.sa.base.common.json.serializer.FileKeyVoSerializer;

import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.math.BigDecimal;
import java.util.List;

@Data
public class ShopAddForm {

        @Schema(description = "商店名称")
        @NotBlank(message = "商品名称不能为空")
        private String shopName;
        @Schema(description = "商店地址编号")
        @NotNull(message = "商店地址编号不能为空")
        private Long placeId;
        @Schema(description = "商店经营范围")
//        @NotBlank(message = "商店经营范围不能为空")
        private List<Long> shopRange;
        @Schema(description = "详细地址")
        private String xxplace;
        @Schema(description = "联系人")
        private String shopLxr;
        @Schema(description = "联系电话")
        @Size(max = 11, message = "联系电话长度不能超过11位")
        private String shopPhone;
        @Schema(description = "商店图片")
        @JsonSerialize(using = FileKeyVoSerializer.class)
        @JsonDeserialize(using = FileKeyVoDeserializer.class)
        private String shopPic;

}
